<?php

namespace app\models\marketing;

use Yii;

/**
 * This is the model class for table "marketing_group_level".
 *
 * @property int $id
 * @property string $name 等级名称
 * @property float $amount 门槛金额(下单+直推)
 * @property float $ratio 返奖比例百分比
 */
class MarketingGroupLevel extends \yii\db\ActiveRecord
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return 'marketing_group_level';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['name'], 'required'],
            [['amount', 'ratio'], 'number'],
            [['name'], 'string', 'max' => 255],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'name' => 'Name',
            'amount' => 'Amount',
            'ratio' => 'Ratio',
        ];
    }
}
